<?php
/**
 * Created by PhpStorm.
 * User: zhulihulian
 * Date: 2017/6/30
 * Time: 12:43
 */

namespace app\api\controller;


use app\api\service\UserToken;
use app\api\validate\TokenGet;
use think\Controller;
use think\Request;

class Token extends Controller
{
    public function getToken($code=''){
        (new TokenGet())->goCheck();
        $ut = new UserToken($code);
        $token = $ut->get();
        return json_encode(['token' => $token]);
    }





}